home *** CD-ROM | disk | FTP | other *** search
- Installing SWI-Prolog
- =====================
-
- Jan Wielemaker
- (jan@swi.psy.uva.nl)
-
-
- Configuration, compilation and installation is now based on the GNU
- autoconf package. It is my hope that this, together with many updates
- to the source code will make the installation much easier on most
- machines.
-
- In normal cases, the following should do:
-
- % cd src
- % ./configure
- % make
- % make install
-
- By default, the system is installed as /usr/local/bin/pl, with the
- libraries in /usr/local/lib/pl-<version>.
-
- % ./configure --prefix=PREFIX
-
- Building for multiple architectures
- ===================================
-
- To build for a second architecture, you should either clean the sources
- using `make distclean' or make a new directory next to the source
- directory and run configure in this directory. The latter procedure
- requires GNU-MAKE. For example:
-
- % mkdir rs6000
- % cd rs6000
- % ../src/configure
- % make
- % make install
-
- Building a runtime version
- ==========================
-
- The runtime version has no tracer, doesn't handle interrupts (just
- exits), has no profiler and no readline included. To build it using a
- separate directory:
-
- % mkdir rt
- % cd rt
- % ../src/configure --enable-runtime
- % make
- % make install
-
- Some things may need attention:
- ===============================
-
- # GNU readline library
-
- When present, SWI-Prolog will automatically include the GNU readline
- library. It is *strongly* adviced to install this library on your
- system. It provides editing of previously entered commands (history) as
- well as completion on Prolog atoms and filenames (for consult, etc.)
- much like the bash and tcsh shells do.
-
- SWI-Prolog has been linked with versions 1.1, 1.2 and 2.0 of the
- readline library.
-
- # Foreign language interface (dynamic linker)
-
- Incremental linking may be based on several mechanisms provided by the
- operating system:
-
- 1) dlopen() and friends.
- 2) HPUX shl_load() and friends.
- 3) Win32 (Windows-NT, '95 and win32s) .DLL interface
- 4) AIX load() and friends
- 5) MACH rld_load() and friends
- 6) BSD Unix `ld -A' combined with reading BSD a.out file
-
- By default, SWI-Prolog will guess whether it can use any of 1-3. to
- support the library(shlib) predicates. On failure, it will try to detect
- the others, supporting the load_foreign/[2,5] dynamic loader. On some
- machines, using 1-3 will conflict with using 4-6. If you want on of 4-6
- anyway (this would only be for obscure backward compatibility reasons),
- you may configure using:
-
- ./configure --disable-shared
-
- # Saved states (save/[1,2], save_program/[1,2])
-
- save/[1,2] and save_program/[1,2] are getting out of fashion as the
- schema proves difficult to port to modern machines using shared libaries
- which make it very hard to gather the process state.
-
- New releases (as of 2.1.4) provide qsave_program/[1,2] which create
- portable saved states that may be loaded on emulators running on
- different hardware.
-
- The default save mechanism is qsave_program/[1,2], which is portable to
- all platforms. The old-fashioned core-dump based mechanism might work on
- some bsd `a.out' format based Unix machines and a few others. If you
- want the system to configure save/[1,2] and save_program/[1,2],
- configure using
-
- ./configure --enable-save
-
- # Memory mapped stacks
-
- Configure will see if mmap() may be used to allocate the stacks. If you
- think this should be possible, but Configure says `no', please work on
- test/mmap.c
-
- # Assembler warnings
-
- If you get assembler warnings compiling pl-wam.c, try #define NO_ASM_NOP
- 1 in config.h. Should be determined automatically by test/nop.c, but
- sometimes appears to fail.
-